apiVersion: v1
kind: Namespace
metadata:
  name: px-kafka
---
apiVersion: v1
kind: Service
metadata:
  annotations:
    cloud.google.com/load-balancer-type: internal
    kompose.cmd: kompose convert
    kompose.version: 1.22.0 (955b78124)
  creationTimestamp: null
  labels:
    io.kompose.service: apache
  name: apache
  namespace: px-kafka
spec:
  ports:
  - port: 8080
    targetPort: 80
  selector:
    io.kompose.service: apache
  type: LoadBalancer
status:
  loadBalancer: {}
---
apiVersion: v1
kind: Service
metadata:
  labels:
    io.kompose.service: invoicing
  name: invoicing
  namespace: px-kafka
spec:
  ports:
  - name: client
    port: 8080
    protocol: TCP
  selector:
    io.kompose.service: invoicing
---
apiVersion: v1
kind: Service
metadata:
  labels:
    io.kompose.service: kafka
  name: kafka-service
  namespace: px-kafka
spec:
  ports:
  - name: kafka
    port: 9092
    protocol: TCP
  selector:
    io.kompose.service: kafka
---
apiVersion: v1
kind: Service
metadata:
  annotations:
    cloud.google.com/load-balancer-type: internal
  labels:
    name: load-test
  name: load-test
  namespace: px-kafka
spec:
  ports:
  - port: 8080
    targetPort: 8089
  selector:
    name: load-test
  type: LoadBalancer
---
apiVersion: v1
kind: Service
metadata:
  labels:
    io.kompose.service: order
  name: order
  namespace: px-kafka
spec:
  ports:
  - name: client
    port: 8080
    protocol: TCP
  selector:
    io.kompose.service: order
---
apiVersion: v1
kind: Service
metadata:
  labels:
    io.kompose.service: postgres
  name: postgres
  namespace: px-kafka
spec:
  ports:
  - name: client
    port: 5432
    protocol: TCP
  selector:
    io.kompose.service: postgres
---
apiVersion: v1
kind: Service
metadata:
  labels:
    io.kompose.service: shipping
  name: shipping
  namespace: px-kafka
spec:
  ports:
  - name: client
    port: 8080
    protocol: TCP
  selector:
    io.kompose.service: shipping
---
apiVersion: v1
kind: Service
metadata:
  labels:
    io.kompose.service: zookeeper
  name: zookeeper
  namespace: px-kafka
spec:
  ports:
  - name: client
    port: 2181
    protocol: TCP
  - name: follower
    port: 2888
    protocol: TCP
  - name: leader
    port: 3888
    protocol: TCP
  selector:
    io.kompose.service: zookeeper
---
apiVersion: apps/v1
kind: Deployment
metadata:
  annotations:
    kompose.cmd: kompose convert
    kompose.version: 1.22.0 (955b78124)
  creationTimestamp: null
  labels:
    io.kompose.service: apache
  name: apache
  namespace: px-kafka
spec:
  replicas: 1
  selector:
    matchLabels:
      io.kompose.service: apache
  strategy: {}
  template:
    metadata:
      annotations:
        kompose.cmd: kompose convert
        kompose.version: 1.22.0 (955b78124)
      creationTimestamp: null
      labels:
        io.kompose.service: apache
    spec:
      containers:
      - image: gcr.io/pixie-prod/demos/kafka/apache:1.0@sha256:d5d1602d4666f5422db47b4ea743e7a2be1b43392b2943fb763ef95757d986dc
        name: apache
        ports:
        - containerPort: 80
        resources: {}
      restartPolicy: Always
status: {}
---
apiVersion: apps/v1
kind: Deployment
metadata:
  annotations:
    kompose.cmd: kompose convert
    kompose.version: 1.22.0 (955b78124)
  creationTimestamp: null
  labels:
    io.kompose.service: invoicing
  name: invoicing
  namespace: px-kafka
spec:
  replicas: 1
  selector:
    matchLabels:
      io.kompose.service: invoicing
  strategy: {}
  template:
    metadata:
      annotations:
        kompose.cmd: kompose convert
        kompose.version: 1.22.0 (955b78124)
      creationTimestamp: null
      labels:
        io.kompose.service: invoicing
    spec:
      containers:
      - env:
        - name: SPRING_KAFKA_BOOTSTRAP_SERVERS
          value: kafka-service:9092
        image: gcr.io/pixie-prod/demos/kafka/invoicing:2.0@sha256:bc49808a900b2b4fede7198a59eba64da204e75edee5909d7a735efb34debdab
        imagePullPolicy: Always
        name: invoicing
        resources: {}
      initContainers:
      - command:
        - sh
        - -c
        - sleep 10
        image: alpine:3.6@sha256:66790a2b79e1ea3e1dabac43990c54aca5d1ddf268d9a5a0285e4167c8b24475
        name: wait-invoicing
      restartPolicy: Always
status: {}
---
apiVersion: apps/v1
kind: Deployment
metadata:
  annotations:
    kompose.cmd: kompose convert
    kompose.version: 1.22.0 (955b78124)
  creationTimestamp: null
  labels:
    io.kompose.service: kafka
  name: kafka
  namespace: px-kafka
spec:
  replicas: 1
  selector:
    matchLabels:
      io.kompose.service: kafka
  strategy: {}
  template:
    metadata:
      annotations:
        kompose.cmd: kompose convert
        kompose.version: 1.22.0 (955b78124)
      creationTimestamp: null
      labels:
        io.kompose.service: kafka
    spec:
      containers:
      - env:
        - name: KAFKA_ADVERTISED_HOST_NAME
          value: kafka-service
        - name: KAFKA_ADVERTISED_PORT
          value: "9092"
        - name: KAFKA_CREATE_TOPICS
          value: order:5:1
        - name: KAFKA_ZOOKEEPER_CONNECT
          value: zookeeper:2181
        - name: KAFKA_AUTO_CREATE_TOPICS_ENABLE
          value: "False"
        - name: JAVA_TOOL_OPTIONS
          value: "-XX:+PreserveFramePointer"
        image: wurstmeister/kafka:2.12-2.5.0@sha256:ed8058aa4ac11f2b08dd1e30bd5683f34d70ed773a0c77e51aa1de2bbcd9c2a8
        name: kafka
        ports:
        - containerPort: 9092
          protocol: TCP
        resources: {}
      restartPolicy: Always
status: {}
---
apiVersion: apps/v1
kind: Deployment
metadata:
  labels:
    name: load-test
  name: load-test
  namespace: px-kafka
spec:
  replicas: 1
  selector:
    matchLabels:
      name: load-test
  template:
    metadata:
      labels:
        name: load-test
    spec:
      containers:
      - args:
        - -u
        - "1"
        - -r
        - "1"
        - --headless
        - -f
        - /config/locustfile.py
        - --host
        - http://apache:8080
        command:
        - locust
        image: gcr.io/pixie-prod/demos/kafka/load-test:1.0@sha256:43cb16a5493f84a6786900f011f49bd7d5b5fe55e85c92cee41b8f435da61416
        imagePullPolicy: Always
        name: load-test
---
apiVersion: apps/v1
kind: Deployment
metadata:
  annotations:
    kompose.cmd: kompose convert
    kompose.version: 1.22.0 (955b78124)
  creationTimestamp: null
  labels:
    io.kompose.service: order
  name: order
  namespace: px-kafka
spec:
  replicas: 1
  selector:
    matchLabels:
      io.kompose.service: order
  strategy: {}
  template:
    metadata:
      annotations:
        kompose.cmd: kompose convert
        kompose.version: 1.22.0 (955b78124)
      creationTimestamp: null
      labels:
        io.kompose.service: order
    spec:
      containers:
      - env:
        - name: SPRING_KAFKA_BOOTSTRAP_SERVERS
          value: kafka-service:9092
        image: gcr.io/pixie-prod/demos/kafka/order:2.0@sha256:7338f1e5521bc02e3f59fc321c8412c24ed48b2944c126ec8e05b922df8aab20
        name: order
        resources: {}
      initContainers:
      - command:
        - sh
        - -c
        - sleep 10
        image: alpine:3.6@sha256:66790a2b79e1ea3e1dabac43990c54aca5d1ddf268d9a5a0285e4167c8b24475
        name: wait-order
      restartPolicy: Always
status: {}
---
apiVersion: apps/v1
kind: Deployment
metadata:
  annotations:
    kompose.cmd: kompose convert
    kompose.version: 1.22.0 (955b78124)
  creationTimestamp: null
  labels:
    io.kompose.service: postgres
  name: postgres
  namespace: px-kafka
spec:
  replicas: 1
  selector:
    matchLabels:
      io.kompose.service: postgres
  strategy: {}
  template:
    metadata:
      annotations:
        kompose.cmd: kompose convert
        kompose.version: 1.22.0 (955b78124)
      creationTimestamp: null
      labels:
        io.kompose.service: postgres
    spec:
      containers:
      - env:
        - name: POSTGRES_PASSWORD
          value: dbpass
        - name: POSTGRES_USER
          value: dbuser
        image: gcr.io/pixie-prod/demos/kafka/postgres:1.0@sha256:32ea3742beb88f7a893a89f86d15979baffc96d8fb1d9e93fada6fb474d3728f
        name: postgres
        resources: {}
      restartPolicy: Always
status: {}
---
apiVersion: apps/v1
kind: Deployment
metadata:
  annotations:
    kompose.cmd: kompose convert
    kompose.version: 1.22.0 (955b78124)
  creationTimestamp: null
  labels:
    io.kompose.service: shipping
  name: shipping
  namespace: px-kafka
spec:
  replicas: 1
  selector:
    matchLabels:
      io.kompose.service: shipping
  strategy: {}
  template:
    metadata:
      annotations:
        kompose.cmd: kompose convert
        kompose.version: 1.22.0 (955b78124)
      creationTimestamp: null
      labels:
        io.kompose.service: shipping
    spec:
      containers:
      - env:
        - name: SPRING_KAFKA_BOOTSTRAP_SERVERS
          value: kafka-service:9092
        image: gcr.io/pixie-prod/demos/kafka/shipping:2.0@sha256:d5b7a2dc93ed23a3e0e018002a5c184362f226559a92e1d6b0ee7e6a3c5d175a
        name: shipping
        resources: {}
      initContainers:
      - command:
        - sh
        - -c
        - sleep 10
        image: alpine:3.6@sha256:66790a2b79e1ea3e1dabac43990c54aca5d1ddf268d9a5a0285e4167c8b24475
        name: wait-shipping
      restartPolicy: Always
status: {}
---
apiVersion: apps/v1
kind: Deployment
metadata:
  annotations:
    kompose.cmd: kompose convert
    kompose.version: 1.22.0 (955b78124)
  creationTimestamp: null
  labels:
    io.kompose.service: zookeeper
  name: zookeeper
  namespace: px-kafka
spec:
  replicas: 1
  selector:
    matchLabels:
      io.kompose.service: zookeeper
  strategy: {}
  template:
    metadata:
      annotations:
        kompose.cmd: kompose convert
        kompose.version: 1.22.0 (955b78124)
      creationTimestamp: null
      labels:
        io.kompose.service: zookeeper
    spec:
      containers:
      - env:
        - name: ZOOKEEPER_CLIENT_PORT
          value: "2181"
        image: gcr.io/pixie-prod/demos/kafka/zookeeper:2.0@sha256:7a7fd44a72104bfbd24a77844bad5fabc86485b036f988ea927d1780782a6680
        name: zookeeper
        ports:
        - containerPort: 2181
          protocol: TCP
        resources: {}
      restartPolicy: Always
status: {}
